package mi.payment.settings;

import java.io.Serializable;

/**
 * 终端密钥管理实体类
 *
 * @author lj on 2017/1/9.
 */
public class TerminalKeyManagementBean implements Serializable {

    // 文件无变化
    private static final long serialVersionUID = 983318039413888606L;
    /**
     * 终端密钥设置的key
     **/
    public final static String TERMINAL_KEY = "terminalKeySettings";

    /**
     * 单DES
     **/
    public final static String SINGLE_DES = "DES";

    /**
     * DES
     **/
    public final static String THREE_DES = "3DES";

    public final static int IC_IMPORT_KEY1 = 1; // 通用
    public final static int IC_IMPORT_KEY2 = 2; // 深银联

    private String terminalKeyIndex = "0";  // 终端密钥索引 默认0
    private String KEK;                     // KEK
    private String des = THREE_DES;         // DES算法
    private int icImportKey;                // 1.通用2.深银联 IC卡导入密钥
    private boolean hasDownloadTMK = false; // 是否下载了TMK

    public String getTerminalKeyIndex() {
        return terminalKeyIndex;
    }

    public String getKEK() {
        return KEK;
    }

    public String getDes() {
        return des;
    }

    public int getIcImportKey() {
        return icImportKey;
    }

    protected void setTerminalKeyIndex(String terminalKeyIndex) {
        this.terminalKeyIndex = terminalKeyIndex;
    }

    protected void setKEK(String KEK) {
        this.KEK = KEK;
    }

    protected void setDes(String des) {
        this.des = des;
    }

    protected void setIcImportKey(int icImportKey) {
        this.icImportKey = icImportKey;
    }

    public boolean isHasDownloadTMK() {
        return hasDownloadTMK;
    }

    protected void setHasDownloadTMK(boolean hasDownloadTMK) {
        this.hasDownloadTMK = hasDownloadTMK;
    }

}
